package com.simple.cms.common;


import com.alibaba.fastjson.JSONObject;
import com.simple.cms.common.utils.NullSafety;


public class JSONObjectWrapper extends JSONObject {

    public int getIntValue(String key, int defaultValue) {
        return NullSafety.valueOrDefault(this.getInteger(key), defaultValue);
    }


    public float getFloatValue(String key, float defaultValue) {
        return NullSafety.valueOrDefault(this.getFloat(key), defaultValue);
    }


}
